From: Scott Bradford Date: Sun, 27 Mar 2016 17:52:15 +0000 (-0400) Subject: Support for iGo Primo POI (.upoi) format. Conversion FROM upoi to other formats is... X-Git-Tag: archive/raspbian/1.10.0+ds-2+rpi1~1^2~12^2~9^2~24^2~8 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=613603fbf9687a932ecbe6068107e28cff137b0c;p=gpsbabel.git Support for iGo Primo POI (.upoi) format. Conversion FROM upoi to other formats is working reliably; conversion TO upoi format results in a file that can't be read by the unit. Investigation continues. --- diff --git a/internal_styles.cc b/internal_styles.cc index 1eb9408b9..0d2ef31e1 100644 --- a/internal_styles.cc +++ b/internal_styles.cc @@ -734,6 +734,45 @@ static char igo2008_poi[] = "IFIELD NOTES, \"\", \"%s\"\n" "IFIELD PHONE_NR, \"\", \"%s\"\n" ; +static char igoprimo_poi[] = + "# gpsbabel XCSV style file\n" + "#\n" + "# Format: iGo Primo points of interest\n" + "# Author: Scott Bradford\n" + "# Date: 03/26/2016\n" + "#\n" + "DESCRIPTION iGo Primo points of interest (.upoi)\n" + "EXTENSION upoi\n" + "DATATYPE WAYPOINT\n" + "#\n" + "# FILE LAYOUT DEFINITIONS:\n" + "#\n" + "FIELD_DELIMITER PIPE\n" + "RECORD_DELIMITER CR\n" + "BADCHARS \"|\n" + "ENCODING windows-1252\n" + "#\n" + "# INDIVIDUAL DATA FIELDS, IN ORDER OF APPEARANCE:\n" + "#\n" + "IFIELD INDEX, \"1\", \"%d\"\n" + "IFIELD CONSTANT, \"@Favourites\", \"%s\" # always @Favourites?\n" + "IFIELD SHORTNAME, \"\", \"%s\"\n" + "IFIELD IGNORE, \"\", \"%s\" # always empty?\n" + "IFIELD LAT_DECIMAL, \"\", \"%.6f\"\n" + "IFIELD LON_DECIMAL, \"\", \"%.6f\"\n" + "IFIELD CONSTANT, \"_u**\", \"%s\" # always _u**?\n" + "IFIELD IGNORE, \"\", \"%s\" # always empty?\n" + "IFIELD CONSTANT, \"_uva\", \"%s\" # always _uva?\n" + "IFIELD IGNORE, \"\", \"%s\" # always empty?\n" + "IFIELD POSTAL_CODE, \"\", \"%s\"\n" + "IFIELD CITY, \"\", \"%s\"\n" + "IFIELD STREET_ADDR, \"\", \"%s\" # should be street name (no number)\n" + "IFIELD IGNORE, \"\", \"%s\" # should be street number\n" + "IFIELD IGNORE, \"\", \"%s\" # always empty?\n" + "IFIELD PHONE_NR, \"\", \"%s\"\n" + "IFIELD IGNORE, \"\", \"%s\" # always empty?\n" + "IFIELD IGNORE, \"\", \"%s\" # seems to be extra lat/lon values?\n" + ; static char kompass_tk[] = "# gpsbabel XCSV style file\n" "#\n" @@ -1450,7 +1489,7 @@ static char xmapwpt[] = "IFIELD IGNORE, \"\", \"%-.31s\"\n" "IFIELD DESCRIPTION, \"\", \"%-.78s\"\n" ; -style_vecs_t style_list[] = {{ "xmapwpt", xmapwpt } , { "xmap2006", xmap2006 } , { "xmap", xmap } , { "tomtom_itn_places", tomtom_itn_places } , { "tomtom_itn", tomtom_itn } , { "tomtom_asc", tomtom_asc } , { "tabsep", tabsep } , { "saplus", saplus } , { "s_and_t", s_and_t } , { "ricoh", ricoh } , { "openoffice", openoffice } , { "nima", nima } , { "navigonwpt", navigonwpt } , { "mxf", mxf } , { "motoactv", motoactv } , { "mapconverter", mapconverter } , { "mainnav", mainnav } , { "land_air_sea", land_air_sea } , { "kompass_wp", kompass_wp } , { "kompass_tk", kompass_tk } , { "igo2008_poi", igo2008_poi } , { "iblue757", iblue757 } , { "iblue747", iblue747 } , { "gpsman", gpsman } , { "gpsdrivetrack", gpsdrivetrack } , { "gpsdrive", gpsdrive } , { "geonet", geonet } , { "garmin_poi", garmin_poi } , { "garmin_g1000", garmin_g1000 } , { "garmin301", garmin301 } , { "fugawi", fugawi } , { "flysight", flysight } , { "dna", dna } , { "custom", custom } , { "cup", cup } , { "csv", csv } , { "cambridge", cambridge } , { "arc", arc } , {0,0}}; +style_vecs_t style_list[] = {{ "xmapwpt", xmapwpt } , { "xmap2006", xmap2006 } , { "xmap", xmap } , { "tomtom_itn_places", tomtom_itn_places } , { "tomtom_itn", tomtom_itn } , { "tomtom_asc", tomtom_asc } , { "tabsep", tabsep } , { "saplus", saplus } , { "s_and_t", s_and_t } , { "ricoh", ricoh } , { "openoffice", openoffice } , { "nima", nima } , { "navigonwpt", navigonwpt } , { "mxf", mxf } , { "motoactv", motoactv } , { "mapconverter", mapconverter } , { "mainnav", mainnav } , { "land_air_sea", land_air_sea } , { "kompass_wp", kompass_wp } , { "kompass_tk", kompass_tk } , { "igo2008_poi", igo2008_poi } , { "igoprimo_poi", igoprimo_poi } , { "iblue757", iblue757 } , { "iblue747", iblue747 } , { "gpsman", gpsman } , { "gpsdrivetrack", gpsdrivetrack } , { "gpsdrive", gpsdrive } , { "geonet", geonet } , { "garmin_poi", garmin_poi } , { "garmin_g1000", garmin_g1000 } , { "garmin301", garmin301 } , { "fugawi", fugawi } , { "flysight", flysight } , { "dna", dna } , { "custom", custom } , { "cup", cup } , { "csv", csv } , { "cambridge", cambridge } , { "arc", arc } , {0,0}}; size_t nstyles = 38; #else /* CSVFMTS_ENABLED */ style_vecs_t style_list[] = {{0,0}}; diff --git a/style/igoprimo_poi.style b/style/igoprimo_poi.style new file mode 100644 index 000000000..3140a2d6d --- /dev/null +++ b/style/igoprimo_poi.style @@ -0,0 +1,37 @@ +# gpsbabel XCSV style file +# +# Format: iGo Primo points of interest +# Author: Scott Bradford +# Date: 03/26/2016 +# +DESCRIPTION iGo Primo points of interest (.upoi) +EXTENSION upoi +DATATYPE WAYPOINT +# +# FILE LAYOUT DEFINITIONS: +# +FIELD_DELIMITER PIPE +RECORD_DELIMITER CR +BADCHARS "| +ENCODING windows-1252 +# +# INDIVIDUAL DATA FIELDS, IN ORDER OF APPEARANCE: +# +IFIELD INDEX, "1", "%d" +IFIELD CONSTANT, "@Favourites", "%s" # always @Favourites? +IFIELD SHORTNAME, "", "%s" +IFIELD IGNORE, "", "%s" # always empty? +IFIELD LAT_DECIMAL, "", "%.6f" +IFIELD LON_DECIMAL, "", "%.6f" +IFIELD CONSTANT, "_u**", "%s" # always _u**? +IFIELD IGNORE, "", "%s" # always empty? +IFIELD CONSTANT, "_uva", "%s" # always _uva? +IFIELD IGNORE, "", "%s" # always empty? +IFIELD POSTAL_CODE, "", "%s" +IFIELD CITY, "", "%s" +IFIELD STREET_ADDR, "", "%s" # should be street name (no number) +IFIELD IGNORE, "", "%s" # should be street number +IFIELD IGNORE, "", "%s" # always empty? +IFIELD PHONE_NR, "", "%s" +IFIELD IGNORE, "", "%s" # always empty? +IFIELD IGNORE, "", "%s" # seems to be extra lat/lon values? \ No newline at end of file diff --git a/testo.d/igoprimo_poi.test b/testo.d/igoprimo_poi.test new file mode 100644 index 000000000..20ff0209c --- /dev/null +++ b/testo.d/igoprimo_poi.test @@ -0,0 +1,8 @@ +# +# igoprimo_poi +# +gpsbabel -i igoprimo_poi -f ${REFERENCE}/igoprimo_poi.upoi -o gpx -F ${TMPDIR}/igoprimo_poi~upoi.gpx +compare ${REFERENCE}/igoprimo_poi~upoi.gpx ${TMPDIR}/igoprimo_poi~upoi.gpx +gpsbabel -i igoprimo_poi -f ${REFERENCE}/igoprimo_poi.upoi -o unicsv -F ${TMPDIR}/igoprimo_poi~upoi.csv +compare ${REFERENCE}/igoprimo_poi~upoi.csv ${TMPDIR}/igoprimo_poi~upoi.csv + diff --git a/xmldoc/formats/igoprimo_poi.xml b/xmldoc/formats/igoprimo_poi.xml new file mode 100644 index 000000000..c5ffa7d46 --- /dev/null +++ b/xmldoc/formats/igoprimo_poi.xml @@ -0,0 +1,5 @@ + + igoprimo_poi supports POI files from iGo Primo 'next generation + navigation' devices. iGo Primo is GPS Navigation Software that runs on Windows embedded + platforms, and is used in some OEM and aftermarket automotive head units. +